<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:ctl="http://arche.auction.co.kr/WebControl/XmlControl" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:s="http://schema.auction.co.kr/Arche.Stores.xsd" xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="ctl s msxsl">
  
  <xsl:import href = "MemberReputation.xsl" />
  <xsl:output indent="no" method="html" encoding="ks_c_5601-1987"/>
  
  <xsl:template match="/">
    <xsl:apply-templates select="/*"/>
  </xsl:template>
  
  <xsl:template match="/*">
    <xsl:param name="AuctionImageBase" />
    <xsl:param name="AuctionImageUrl" />
    <xsl:param name="AuctionUrl"> <xsl:value-of select="$AuctionImageBase" /></xsl:param>
    <xsl:param name="LogoImageBase" />
    <xsl:param name="FrontImageBase" />
    <xsl:param name="SubMenuName" />
    <xsl:param name="EnableRegisterFavoriteStore" />
    <xsl:param name="HeaderWidth" />
    <xsl:param name="Satisfaction" />
    <xsl:param name="IsDisplayPercent" />
    <xsl:param name="IsTrustSeller" />
    <xsl:param name="Sell3Url" />
    
    <xsl:variable name="BlankImage" select="concat($FrontImageBase,&apos;/blank.gif&apos;)"/>
    <script language="javascript" src="/auction/jscript/credit_over.js"/>
    <script language="javascript" src="http://script.auction.co.kr/sell/FavoriteStore.js"/>
    
    <link rel="stylesheet" type="text/css" href="http://script.auction.co.kr/style/css/frame/list.css"/>
	<link rel="stylesheet" type="text/css" href="http://script.auction.co.kr/style/css/common/type2.css"/>
	<link rel="stylesheet" type="text/css" href="http://script.auction.co.kr/style/css/store/store.css"/>
	<script type="text/javascript" src="http://script.auction.co.kr/style/js/common.js"></script>
    <xsl:call-template name="Script">
      <xsl:with-param name="scriptText">
<![CDATA[
    // 스토어 관리자 메뉴에서 현위치 표시 부분에 나머지를 출력하기 위한 스크립트
    var manageMenu = new Array();
    //manageMenu[0] = [파일명, 상세메뉴제목명];
    //manageMenu[0] = ["", "", "", "", ""];
    function strPresentLocation(storeID, storeUrl, storeName, subMenuName, auctionUrl)
    {
      var strLocation = "<a href=\"" + auctionUrl + "\">홈</a> &gt; <a href=\"/\">스토어 홈</a> &gt; <a href=\"/" + storeUrl + "\"><strong>" + storeName + "</strong></a>";
      var strDocumentUrl = document.URLUnencoded;
            
      var strTestPattern = /auction\/management/ig;
      if (strTestPattern.test(strDocumentUrl))
      {
        strLocation = "<a href=\"" + auctionUrl + "\">홈</a> &gt; <a href=\"/\">스토어 홈</a> &gt; <a href=\"/" + storeUrl + "\">" + storeName + "</a> &gt; <a href=\"\/auction\/management/\"><strong>나의 스토어 관리<strong></a>";
        
        if(subMenuName.length > 1 )
        {
          strLocation = "<a href=\"" + auctionUrl + "\">홈</a> &gt; <a href=\"/\">스토어 홈</a> &gt; <a href=\"/" + storeUrl + "\">" + storeName + "</a> &gt; <a href=\"\/auction\/management/\">나의 스토어 관리</a> &gt; <strong>"+ subMenuName + "</strong>";
        }
      }
      return strLocation;
    }

]]>
</xsl:with-param>
    </xsl:call-template>
    
 
    
    <xsl:if test="$HeaderWidth='975'">
    
<div style="width:900px;margin:0 auto;">
    <!-- 스토어 소개 폼1 -->
<div class="storetemplebox">
	<xsl:if test="@TopLogoPath and string-length(@TopLogoPath)">
	<div class="storeimg">		
		<img>
			<xsl:attribute name="src">
				<xsl:value-of select="concat($LogoImageBase, @TopLogoPath)"/>
			</xsl:attribute>
		</img>		
	</div>
	<div class="storetxt">
		<div style="background:#DF5855; width:645px;">
		<table width="645">
		<tr class="store_title_background">
			<td width="1"><img src="http://pics.auction.co.kr/store/dot02.gif"></img></td>
			<td width="543"><h6><font class="store_title_text"><img src="http://pics.auction.co.kr/store/dot01.gif" class="vm"></img><xsl:value-of select="@Name" disable-output-escaping="yes"/></font></h6></td>
			<xsl:if test="$EnableRegisterFavoriteStore=&apos;True&apos;">
				<td width="100">
					<img style="CURSOR: hand">
						<xsl:attribute name="onclick">
							<xsl:value-of select='concat(&quot;javascript:FavoriteStore.open(this, &apos;&quot;, @OwnerID, &quot;&apos;,&apos;&quot;, $Sell3Url, &quot;&apos;)&quot;)'/>
						</xsl:attribute>
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/btn_regi.gif&apos;)"/>
						</xsl:attribute>
					</img>
				</td>
			</xsl:if>
			<xsl:if test="$EnableRegisterFavoriteStore=&apos;False&apos;">
				<td width="106">
					<img style="CURSOR: hand">
						<xsl:attribute name="onclick">
							<xsl:value-of select='&quot;javascript:goStoreManagement()&quot;'/>
						</xsl:attribute>
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/btn_mystorego.gif&apos;)"/>
						</xsl:attribute>
					</img>
				</td>
			</xsl:if>
			<td width="1"><img src="http://pics.auction.co.kr/store/dot02.gif"></img></td>
		</tr>
		</table>
		</div>
		<table>
		<tr>
			<td class="ptx" >
				<font class="store_intro_text">
				<xsl:call-template name="Replace-Enter">
					<xsl:with-param name="text" select="@Info"/>
				</xsl:call-template>
				</font>
			</td>
		</tr>
		</table>
		<div class="storeinfo">
			<ul>
				<li>판매자아이디 : 					
					<a>
						<xsl:attribute name="href">
							<xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
						</xsl:attribute>
						<xsl:value-of select="@OwnerID"/>
					</a> 					
					<xsl:if test="$IsTrustSeller = &apos;true&apos;">						
						<xsl:text> </xsl:text>
						<img id="iTrustSeller" class="sell">
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/icon&apos;, &apos;/trustseller.gif&apos;)"/>							
						</xsl:attribute>
						</img>
					</xsl:if>
					<xsl:if test="s:SellerCredit/@IsPowerSeller = &apos;true&apos;">						
						<xsl:text> </xsl:text>
						<img id="iPowerSeller" class="sell">
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/icon&apos;,&apos;/powerseller.gif&apos;)"/>
						</xsl:attribute>
						</img>
					</xsl:if>					
				</li>
				<li> 					
					<!--판매만족도 :a enableCredit="true" onmouseover="ShowDegreeHelp(&apos;판매만족도 도움말 입니다.&apos;)" onmouseout="nd()">
						<xsl:attribute name="href">
							<xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
						</xsl:attribute>
						판매만족도</a-->
					<!--img src="http://pics.auction.co.kr/icon/star1.gif"></img><img src="http://pics.auction.co.kr/icon/star1.gif"></img><img src="http://pics.auction.co.kr/icon/star_half.gif"></img><img src="http://pics.auction.co.kr/icon/star0.gif"></img><img src="http://pics.auction.co.kr/icon/star0.gif"></img-->								
				<table>
				<tr>
				<td>판매만족도 :</td>
				<xsl:call-template name="PrintStar">
					<xsl:with-param name="DegreeImageType">SmallStar</xsl:with-param>
					<xsl:with-param name="IsDisplayPercent">true</xsl:with-param>
					<xsl:with-param name="Satisfaction" select="s:SellerCredit/@Satisfaction" />
					<xsl:with-param name="SatisfactionPercent" select="s:SellerCredit/@SatisfactionPercent" />
				</xsl:call-template>
				</tr>
				</table>
				</li>
				<li>판매등급 : 
					<xsl:choose>
						<xsl:when test="s:SellerCredit/@Grade &gt; 0 ">
						<img align="absmiddle" border="0" height="16">
							<xsl:attribute name="src">
								<xsl:value-of select="concat($AuctionImageUrl,&apos;/common/a&apos;, s:SellerCredit/@Grade, &apos;.gif&apos;) "/>
							</xsl:attribute>
						</img>
						</xsl:when>
						<xsl:otherwise>
							<xsl:text>새내기</xsl:text>
						</xsl:otherwise>
					</xsl:choose>
				</li>
				<!--a onmouseover="ShowGradeHelp(&apos;판매등급 도움말 입니다.&apos;)" onmouseout="nd()">
                  <xsl:attribute name="href">
                    <xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
                  </xsl:attribute>
                  <u>판매등급</u>
                </a>
                <a>
                  <xsl:attribute name="href">
                    <xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
                  </xsl:attribute>
                </a-->
			</ul>
		</div>
	</div>
	<div class="trustseller">
		<xsl:if test="$IsTrustSeller = &apos;true&apos;">						
			<img>
				<xsl:attribute name="src">
					<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/logo_trust.gif&apos;)"/>							
				</xsl:attribute>
			</img>
		</xsl:if>		
	</div>
</xsl:if>	




<xsl:if test="string-length(@TopLogoPath) = 0">
	<div class="storetxt">
		<div style="width:880px; padding-left:10px;">
		<table width="880">
		<tr class="store_title_background">
			<td width="1"><img src="http://pics.auction.co.kr/store/dot02.gif"></img></td>
			<td width="778"><h6><font class="store_title_text"><img src="http://pics.auction.co.kr/store/dot01.gif" class="vm"></img><xsl:value-of select="@Name" disable-output-escaping="yes"/></font></h6></td>
			<xsl:if test="$EnableRegisterFavoriteStore=&apos;True&apos;">
				<td width="100">
					<img style="CURSOR: hand">
						<xsl:attribute name="onclick">
							<xsl:value-of select='concat(&quot;javascript:FavoriteStore.open(this, &apos;&quot;, @OwnerID, &quot;&apos;,&apos;&quot;, $Sell3Url, &quot;&apos;)&quot;)'/>
						</xsl:attribute>
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/btn_regi.gif&apos;)"/>
						</xsl:attribute>
					</img>
				</td>
			</xsl:if>
			<xsl:if test="$EnableRegisterFavoriteStore=&apos;False&apos;">
				<td width="106">
					<img style="CURSOR: hand">
						<xsl:attribute name="onclick">
							<xsl:value-of select='&quot;javascript:goStoreManagement()&quot;'/>
						</xsl:attribute>
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/btn_mystorego.gif&apos;)"/>
						</xsl:attribute>
					</img>
				</td>
			</xsl:if>
			<td width="1"><img src="http://pics.auction.co.kr/store/dot02.gif"></img></td>
		</tr>
		</table>
		</div>
		<table>
		<tr>
			<td class="ptx" style="padding-left:20px;">
				<font class="store_intro_text">
				<xsl:call-template name="Replace-Enter">
					<xsl:with-param name="text" select="@Info"/>
				</xsl:call-template>
				</font>
			</td>
		</tr>
		</table>
		<table>
		<tr>
		<td style="padding-left:10px;">
		<div class="storeinfo2">
			<ul>
				<li>판매자아이디 : 					
					<a>
						<xsl:attribute name="href">
							<xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
						</xsl:attribute>
						<xsl:value-of select="@OwnerID"/>
					</a> 					
					<xsl:if test="$IsTrustSeller = &apos;true&apos;">						
						<xsl:text> </xsl:text>
						<img id="iTrustSeller" class="sell">
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/icon&apos;, &apos;/trustseller.gif&apos;)"/>							
						</xsl:attribute>
						</img>
					</xsl:if>
					<xsl:if test="s:SellerCredit/@IsPowerSeller = &apos;true&apos;">						
						<xsl:text> </xsl:text>
						<img id="iPowerSeller" class="sell">
						<xsl:attribute name="src">
							<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/icon&apos;,&apos;/powerseller.gif&apos;)"/>
						</xsl:attribute>
						</img>
					</xsl:if>					
				</li>
				<li> 					
					<!--판매만족도 :a enableCredit="true" onmouseover="ShowDegreeHelp(&apos;판매만족도 도움말 입니다.&apos;)" onmouseout="nd()">
						<xsl:attribute name="href">
							<xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
						</xsl:attribute>
						판매만족도</a-->
					<!--img src="http://pics.auction.co.kr/icon/star1.gif"></img><img src="http://pics.auction.co.kr/icon/star1.gif"></img><img src="http://pics.auction.co.kr/icon/star_half.gif"></img><img src="http://pics.auction.co.kr/icon/star0.gif"></img><img src="http://pics.auction.co.kr/icon/star0.gif"></img-->								
				<table>
				<tr>
				<td>판매만족도 :</td>
				<xsl:call-template name="PrintStar">
					<xsl:with-param name="DegreeImageType">SmallStar</xsl:with-param>
					<xsl:with-param name="IsDisplayPercent">true</xsl:with-param>
					<xsl:with-param name="Satisfaction" select="s:SellerCredit/@Satisfaction" />
					<xsl:with-param name="SatisfactionPercent" select="s:SellerCredit/@SatisfactionPercent" />
				</xsl:call-template>
				</tr>
				</table>
				</li>
				<li>판매등급 : 
					<xsl:choose>
						<xsl:when test="s:SellerCredit/@Grade &gt; 0 ">
						<img align="absmiddle" border="0" height="16">
							<xsl:attribute name="src">
								<xsl:value-of select="concat($AuctionImageUrl,&apos;/common/a&apos;, s:SellerCredit/@Grade, &apos;.gif&apos;) "/>
							</xsl:attribute>
						</img>
						</xsl:when>
						<xsl:otherwise>
							<xsl:text>새내기</xsl:text>
						</xsl:otherwise>
					</xsl:choose>
				</li>
				<!--a onmouseover="ShowGradeHelp(&apos;판매등급 도움말 입니다.&apos;)" onmouseout="nd()">
                  <xsl:attribute name="href">
                    <xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
                  </xsl:attribute>
                  <u>판매등급</u>
                </a>
                <a>
                  <xsl:attribute name="href">
                    <xsl:value-of select="concat($AuctionUrl, '/buy/credit.asp?id=',@OwnerID)"/>
                  </xsl:attribute>
                </a-->
			</ul>
		</div>
		</td>
		</tr>
		</table>
	</div>
	<div class="trustseller">
		<xsl:if test="$IsTrustSeller = &apos;true&apos;">						
			<img>
				<xsl:attribute name="src">
					<xsl:value-of select="concat(&apos;http://pics.auction.co.kr/store&apos;, &apos;/logo_trust.gif&apos;)"/>							
				</xsl:attribute>
			</img>
		</xsl:if>		
	</div>
</xsl:if>
	

</div>
<!-- 스토어 소개 폼1 //-->
</div>
</xsl:if>      
  </xsl:template>

  <xsl:template name="Image">
    <xsl:param name="count"/>
    <xsl:param name="src"/>
    <xsl:if test="$count &gt; 0">  
    <img align="absmiddle" width="12" height="12" border="0">
      <xsl:attribute name="src">
        <xsl:value-of select="$src"/>
      </xsl:attribute>
    </img>  
      <xsl:call-template name="Image">
        <xsl:with-param name="count" select="$count - 1"/>
        <xsl:with-param name="src" select="$src"/>
      </xsl:call-template>
    </xsl:if>
  </xsl:template>
  
  
  <xsl:template name="Script">
    <xsl:param name="scriptText"/>
    <xsl:element name="script">
      <xsl:attribute name="language">javascript</xsl:attribute>
      <xsl:text> 
</xsl:text>
      <xsl:comment>
        <xsl:text> 
</xsl:text>
        <xsl:value-of select="$scriptText"/>
        <xsl:text> 
//</xsl:text>
      </xsl:comment>
      <xsl:text> 
</xsl:text>
    </xsl:element>
  </xsl:template>
  
<!-- replace cr(\n) to <br/> function -->
<xsl:template name="Replace-Enter">
 <xsl:param name="text"/>
 <xsl:variable name="from" select="'&#xA;'"/> <!-- \n문자 -->
 
 <xsl:choose>
  <xsl:when test="contains($text, $from)">
   <xsl:variable name="before" select="substring-before($text, $from)"/>
   <xsl:variable name="after" select="substring-after($text, $from)"/>
   
   <xsl:value-of select="$before"/>
   <br/>
   <xsl:call-template name="Replace-Enter">
    <xsl:with-param name="text" select="$after"/>
    <xsl:with-param name="from" select="$from"/>
   </xsl:call-template>
  </xsl:when> 
  <xsl:otherwise>
   <xsl:value-of select="$text"/>  
  </xsl:otherwise>
 </xsl:choose>            
</xsl:template>
  
</xsl:stylesheet>